<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.12.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>MDF Lib: include/mdf/mdfreader.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="clipboard.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="utillib.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr id="projectrow">
  <td id="projectalign">
   <div id="projectname">MDF Lib<span id="projectnumber">&#160;2.2</span>
   </div>
   <div id="projectbrief">Interface against MDF 3/4 files</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.12.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() { codefold.init(0); });
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
  initMenu('',true,false,'search.php','Search',false);
  $(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){ initResizable(false); });
/* @license-end */
</script>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="dir_dea88a92c3ac1d8c329848683c200b71.html">mdf</a></li>  </ul>
</div>
</div><!-- top -->
<div id="doc-content">
<div class="header">
  <div class="headertitle"><div class="title">mdfreader.h</div></div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno">    1</span><span class="comment">/*</span></div>
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno">    2</span><span class="comment"> * Copyright 2021 Ingemar Hedvall</span></div>
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno">    3</span><span class="comment"> * SPDX-License-Identifier: MIT</span></div>
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno">    4</span><span class="comment"> */</span></div>
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno">    5</span> </div>
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno">    6</span><span class="preprocessor">#pragma once</span></div>
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno">    7</span><span class="preprocessor">#include &lt;cstdio&gt;</span></div>
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno">    8</span><span class="preprocessor">#include &lt;memory&gt;</span></div>
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno">    9</span><span class="preprocessor">#include &lt;string&gt;</span></div>
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno">   10</span><span class="preprocessor">#include &lt;functional&gt;</span></div>
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno">   11</span><span class="preprocessor">#include &lt;vector&gt;</span></div>
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno">   12</span> </div>
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno">   13</span><span class="preprocessor">#include &quot;<a class="code" href="ichannelobserver_8h.html">mdf/ichannelobserver.h</a>&quot;</span></div>
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno">   14</span><span class="preprocessor">#include &quot;<a class="code" href="mdffile_8h.html">mdf/mdffile.h</a>&quot;</span></div>
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno">   15</span><span class="preprocessor">#include &quot;<a class="code" href="isamplereduction_8h.html">mdf/isamplereduction.h</a>&quot;</span></div>
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno">   16</span> </div>
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno">   17</span><span class="keyword">namespace </span><a class="code hl_namespace" href="namespacemdf.html">mdf</a> {</div>
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno">   18</span> </div>
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno">   19</span><span class="keyword">class </span>IChannelGroup;</div>
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno">   20</span> </div>
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"><a class="line" href="namespacemdf.html#a5964a13a2ccb66953e040af87d62e2da">   22</a></span><span class="keyword">using </span><a class="code hl_typedef" href="namespacemdf.html#a5964a13a2ccb66953e040af87d62e2da">ChannelObserverPtr</a> = std::unique_ptr&lt;IChannelObserver&gt;;</div>
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"><a class="line" href="namespacemdf.html#a704962c842a2b4ae11010c7fcb26b0de">   24</a></span><span class="keyword">using </span><a class="code hl_typedef" href="namespacemdf.html#a704962c842a2b4ae11010c7fcb26b0de">ChannelObserverList</a> = std::vector&lt;ChannelObserverPtr&gt;;</div>
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno">   25</span> </div>
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"><a class="line" href="namespacemdf.html#a36bdce80788796d1ee3482bfe48c3f96">   27</a></span>[[nodiscard]] <span class="keywordtype">bool</span> <a class="code hl_function" href="namespacemdf.html#a36bdce80788796d1ee3482bfe48c3f96">IsMdfFile</a>(<span class="keyword">const</span> std::string&amp; filename);</div>
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno">   28</span> </div>
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"><a class="line" href="namespacemdf.html#a16a866b3ee857add084d1d8e8b2e7aa3">   30</a></span>[[nodiscard]] <a class="code hl_typedef" href="namespacemdf.html#a5964a13a2ccb66953e040af87d62e2da">ChannelObserverPtr</a> <a class="code hl_function" href="namespacemdf.html#a16a866b3ee857add084d1d8e8b2e7aa3">CreateChannelObserver</a>(</div>
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno">   31</span>    <span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a>&amp; data_group, <span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_channel_group.html">IChannelGroup</a>&amp; group,</div>
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno">   32</span>    <span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_channel.html">IChannel</a>&amp; channel);</div>
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"><a class="line" href="namespacemdf.html#aa3db89e1164d41e240176bbf3681aeb3">   41</a></span>[[nodiscard]] <a class="code hl_typedef" href="namespacemdf.html#a5964a13a2ccb66953e040af87d62e2da">ChannelObserverPtr</a> <a class="code hl_function" href="namespacemdf.html#a16a866b3ee857add084d1d8e8b2e7aa3">CreateChannelObserver</a>(</div>
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno">   42</span>    <span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a>&amp; dg_group, <span class="keyword">const</span> std::string&amp; channel_name);</div>
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno">   43</span> </div>
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"><a class="line" href="namespacemdf.html#a7d36a3f5f140f8be0a7d4bebc9be7eeb">   45</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="namespacemdf.html#a7d36a3f5f140f8be0a7d4bebc9be7eeb">CreateChannelObserverForChannelGroup</a>(<span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a>&amp; data_group,</div>
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno">   46</span>                                          <span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_channel_group.html">IChannelGroup</a>&amp; group,</div>
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno">   47</span>                                          <a class="code hl_typedef" href="namespacemdf.html#a704962c842a2b4ae11010c7fcb26b0de">ChannelObserverList</a>&amp; dest);</div>
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno">   48</span> </div>
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"><a class="line" href="namespacemdf.html#a9cfa60a833d0bbb41342775cda9c52c1">   61</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="namespacemdf.html#a9cfa60a833d0bbb41342775cda9c52c1">CreateChannelObserverForDataGroup</a>(<span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a>&amp; data_group,</div>
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno">   62</span>                                          <a class="code hl_typedef" href="namespacemdf.html#a704962c842a2b4ae11010c7fcb26b0de">ChannelObserverList</a>&amp; dest_list);</div>
<div class="foldopen" id="foldopen00068" data-start="{" data-end="};">
<div class="line"><a id="l00068" name="l00068"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html">   68</a></span><span class="keyword">class </span><a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a> {</div>
<div class="line"><a id="l00069" name="l00069"></a><span class="lineno">   69</span> <span class="keyword">public</span>:</div>
<div class="line"><a id="l00070" name="l00070"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#aa7f0b2856814655ad23f99dd76bc7d44">   70</a></span>  <span class="keyword">explicit</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#aa7f0b2856814655ad23f99dd76bc7d44">MdfReader</a>(</div>
<div class="line"><a id="l00071" name="l00071"></a><span class="lineno">   71</span>      <span class="keyword">const</span> std::string&amp; filename);  </div>
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a8d21b5d7336b34547a049e07fd1408cc">   73</a></span>  <span class="keyword">virtual</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a8d21b5d7336b34547a049e07fd1408cc">~MdfReader</a>();  </div>
<div class="line"><a id="l00074" name="l00074"></a><span class="lineno">   74</span> </div>
<div class="line"><a id="l00075" name="l00075"></a><span class="lineno">   75</span>  <a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>() = <span class="keyword">delete</span>;</div>
<div class="line"><a id="l00076" name="l00076"></a><span class="lineno">   76</span>  <a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>(<span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno">   77</span>  <a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>(<a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>&amp;&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a id="l00078" name="l00078"></a><span class="lineno">   78</span>  <a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>&amp; operator=(<span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a id="l00079" name="l00079"></a><span class="lineno">   79</span>  <a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>&amp; operator=(<a class="code hl_class" href="classmdf_1_1_mdf_reader.html">MdfReader</a>&amp;&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a id="l00080" name="l00080"></a><span class="lineno">   80</span> </div>
<div class="line"><a id="l00086" name="l00086"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#af0675cacfb831f8700c9c323feb42ef8">   86</a></span>  [[nodiscard]] int64_t <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#af0675cacfb831f8700c9c323feb42ef8">Index</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> index_; }</div>
<div class="line"><a id="l00087" name="l00087"></a><span class="lineno">   87</span> </div>
<div class="line"><a id="l00094" name="l00094"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a53daae43b08717a2178f73270188d019">   94</a></span>  <span class="keywordtype">void</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a53daae43b08717a2178f73270188d019">Index</a>(int64_t index) { index_ = index; }</div>
<div class="line"><a id="l00095" name="l00095"></a><span class="lineno">   95</span> </div>
<div class="line"><a id="l00098" name="l00098"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a0ba4d7ff6bc5500427f093771c1762e6">   98</a></span>  [[nodiscard]] <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a0ba4d7ff6bc5500427f093771c1762e6">IsOk</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <span class="keyword">static_cast&lt;</span><span class="keywordtype">bool</span><span class="keyword">&gt;</span>(instance_); }</div>
<div class="line"><a id="l00099" name="l00099"></a><span class="lineno">   99</span> </div>
<div class="line"><a id="l00106" name="l00106"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#af98f1f425b626097e2728185f3c2eb8a">  106</a></span>  [[nodiscard]] <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#af98f1f425b626097e2728185f3c2eb8a">IsFinalized</a>() <span class="keyword">const</span>;</div>
<div class="line"><a id="l00107" name="l00107"></a><span class="lineno">  107</span> </div>
<div class="line"><a id="l00111" name="l00111"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a590c1e3a97b2a69f6e2cb203badd2282">  111</a></span>  [[nodiscard]] <span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_mdf_file.html">MdfFile</a>* <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a590c1e3a97b2a69f6e2cb203badd2282">GetFile</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> instance_.get(); }</div>
<div class="line"><a id="l00112" name="l00112"></a><span class="lineno">  112</span> </div>
<div class="line"><a id="l00114" name="l00114"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a9abc5d58be4d23b0b1c476d8a3a3a4d3">  114</a></span>  [[nodiscard]] <span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_header.html">IHeader</a>* <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a9abc5d58be4d23b0b1c476d8a3a3a4d3">GetHeader</a>() <span class="keyword">const</span>;</div>
<div class="line"><a id="l00116" name="l00116"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a8f05147406ef2de50559a35c4c399abb">  116</a></span>  [[nodiscard]] <a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a>* <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a8f05147406ef2de50559a35c4c399abb">GetDataGroup</a>(<span class="keywordtype">size_t</span> order) <span class="keyword">const</span>;</div>
<div class="line"><a id="l00117" name="l00117"></a><span class="lineno">  117</span> </div>
<div class="line"><a id="l00118" name="l00118"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a8e6380bb34582a34eec11b693648d6d5">  118</a></span>  [[nodiscard]] std::string <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a8e6380bb34582a34eec11b693648d6d5">ShortName</a>()</div>
<div class="line"><a id="l00119" name="l00119"></a><span class="lineno">  119</span>      <span class="keyword">const</span>;  </div>
<div class="line"><a id="l00120" name="l00120"></a><span class="lineno">  120</span> </div>
<div class="line"><a id="l00121" name="l00121"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a95758453003b0132b6324101096611b1">  121</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a95758453003b0132b6324101096611b1">Open</a>();   </div>
<div class="line"><a id="l00122" name="l00122"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#abcd1fda3384e9d538803e0504c4cc7a4">  122</a></span>  <span class="keywordtype">void</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#abcd1fda3384e9d538803e0504c4cc7a4">Close</a>();  </div>
<div class="line"><a id="l00123" name="l00123"></a><span class="lineno">  123</span> </div>
<div class="line"><a id="l00124" name="l00124"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a4e1b3dca5f2b9d0c8b80ecdf843d86ba">  124</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a4e1b3dca5f2b9d0c8b80ecdf843d86ba">ReadHeader</a>();             </div>
<div class="line"><a id="l00125" name="l00125"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a4eb4a1808b4826a6befa2a608790e707">  125</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a4eb4a1808b4826a6befa2a608790e707">ReadMeasurementInfo</a>();    </div>
<div class="line"><a id="l00126" name="l00126"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a64bd57d67582f7cb2f911f4d427fb5ce">  126</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a64bd57d67582f7cb2f911f4d427fb5ce">ReadEverythingButData</a>();  </div>
<div class="line"><a id="l00127" name="l00127"></a><span class="lineno">  127</span> </div>
<div class="line"><a id="l00129" name="l00129"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a8209013830f087b0f08a281259361108">  129</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a8209013830f087b0f08a281259361108">ExportAttachmentData</a>(<span class="keyword">const</span> <a class="code hl_class" href="classmdf_1_1_i_attachment.html">IAttachment</a>&amp; attachment,</div>
<div class="line"><a id="l00130" name="l00130"></a><span class="lineno">  130</span>                            <span class="keyword">const</span> std::string&amp; dest_file);</div>
<div class="line"><a id="l00131" name="l00131"></a><span class="lineno">  131</span> </div>
<div class="line"><a id="l00145" name="l00145"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a3a7b46a48cac62ed16897f28f3649ba9">  145</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a3a7b46a48cac62ed16897f28f3649ba9">ReadData</a>(<a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a>&amp; data_group);</div>
<div class="line"><a id="l00146" name="l00146"></a><span class="lineno">  146</span> </div>
<div class="line"><a id="l00166" name="l00166"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a0e19cc38b9ea526c3020398738a3db64">  166</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a0e19cc38b9ea526c3020398738a3db64">ReadPartialData</a>(<a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a>&amp; data_group, <span class="keywordtype">size_t</span> min_sample,</div>
<div class="line"><a id="l00167" name="l00167"></a><span class="lineno">  167</span>                       <span class="keywordtype">size_t</span> max_sample);</div>
<div class="line"><a id="l00168" name="l00168"></a><span class="lineno">  168</span> </div>
<div class="line"><a id="l00177" name="l00177"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a2f1c16a9230973d05788b49b81ca32fd">  177</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a2f1c16a9230973d05788b49b81ca32fd">ReadSrData</a>(<a class="code hl_class" href="classmdf_1_1_i_sample_reduction.html">ISampleReduction</a>&amp; sr_group);</div>
<div class="line"><a id="l00178" name="l00178"></a><span class="lineno">  178</span> </div>
<div class="line"><a id="l00198" name="l00198"></a><span class="lineno"><a class="line" href="classmdf_1_1_mdf_reader.html#a21b97f7036c49f6beb2f7f5772c6fde9">  198</a></span>  <span class="keywordtype">bool</span> <a class="code hl_function" href="classmdf_1_1_mdf_reader.html#a21b97f7036c49f6beb2f7f5772c6fde9">ReadVlsdData</a>(<a class="code hl_class" href="classmdf_1_1_i_data_group.html">IDataGroup</a> &amp;data_group,</div>
<div class="line"><a id="l00199" name="l00199"></a><span class="lineno">  199</span>                    <a class="code hl_class" href="classmdf_1_1_i_channel.html">IChannel</a> &amp;vlsd_channel,</div>
<div class="line"><a id="l00200" name="l00200"></a><span class="lineno">  200</span>                    <span class="keyword">const</span> std::vector&lt;uint64_t&gt;&amp; offset_list,</div>
<div class="line"><a id="l00201" name="l00201"></a><span class="lineno">  201</span>                    std::function&lt;<span class="keywordtype">void</span>(uint64_t,</div>
<div class="line"><a id="l00202" name="l00202"></a><span class="lineno">  202</span>                                       <span class="keyword">const</span> std::vector&lt;uint8_t&gt;&amp;)&gt;&amp; callback);</div>
<div class="line"><a id="l00203" name="l00203"></a><span class="lineno">  203</span> </div>
<div class="line"><a id="l00204" name="l00204"></a><span class="lineno">  204</span> </div>
<div class="line"><a id="l00205" name="l00205"></a><span class="lineno">  205</span> <span class="keyword">private</span>:</div>
<div class="line"><a id="l00206" name="l00206"></a><span class="lineno">  206</span>  std::FILE* file_ = <span class="keyword">nullptr</span>;          </div>
<div class="line"><a id="l00207" name="l00207"></a><span class="lineno">  207</span>  std::string filename_;               </div>
<div class="line"><a id="l00208" name="l00208"></a><span class="lineno">  208</span>  std::unique_ptr&lt;MdfFile&gt; instance_;  </div>
<div class="line"><a id="l00209" name="l00209"></a><span class="lineno">  209</span>  int64_t index_ = 0;  </div>
<div class="line"><a id="l00211" name="l00211"></a><span class="lineno">  211</span>};</div>
</div>
<div class="line"><a id="l00212" name="l00212"></a><span class="lineno">  212</span> </div>
<div class="line"><a id="l00213" name="l00213"></a><span class="lineno">  213</span>}  <span class="comment">// namespace mdf</span></div>
<div class="ttc" id="aclassmdf_1_1_i_attachment_html"><div class="ttname"><a href="classmdf_1_1_i_attachment.html">mdf::IAttachment</a></div><div class="ttdoc">Interface against an attached file.</div><div class="ttdef"><b>Definition</b> iattachment.h:21</div></div>
<div class="ttc" id="aclassmdf_1_1_i_channel_group_html"><div class="ttname"><a href="classmdf_1_1_i_channel_group.html">mdf::IChannelGroup</a></div><div class="ttdoc">Interface against a channel group (CG) block.</div><div class="ttdef"><b>Definition</b> ichannelgroup.h:66</div></div>
<div class="ttc" id="aclassmdf_1_1_i_channel_html"><div class="ttname"><a href="classmdf_1_1_i_channel.html">mdf::IChannel</a></div><div class="ttdoc">Defines a MDF channel (CN) block.</div><div class="ttdef"><b>Definition</b> ichannel.h:126</div></div>
<div class="ttc" id="aclassmdf_1_1_i_data_group_html"><div class="ttname"><a href="classmdf_1_1_i_data_group.html">mdf::IDataGroup</a></div><div class="ttdoc">Interface to a data group (DG) block.</div><div class="ttdef"><b>Definition</b> idatagroup.h:42</div></div>
<div class="ttc" id="aclassmdf_1_1_i_header_html"><div class="ttname"><a href="classmdf_1_1_i_header.html">mdf::IHeader</a></div><div class="ttdoc">Interface class against an MDF HD block.</div><div class="ttdef"><b>Definition</b> iheader.h:34</div></div>
<div class="ttc" id="aclassmdf_1_1_i_sample_reduction_html"><div class="ttname"><a href="classmdf_1_1_i_sample_reduction.html">mdf::ISampleReduction</a></div><div class="ttdoc">Defines an interface to a sample reduction (SR) block.</div><div class="ttdef"><b>Definition</b> isamplereduction.h:58</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_file_html"><div class="ttname"><a href="classmdf_1_1_mdf_file.html">mdf::MdfFile</a></div><div class="ttdoc">Implements an user interface against a MDF file.</div><div class="ttdef"><b>Definition</b> mdffile.h:37</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html">mdf::MdfReader</a></div><div class="ttdoc">Reader interface to an MDF file.</div><div class="ttdef"><b>Definition</b> mdfreader.h:68</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a0ba4d7ff6bc5500427f093771c1762e6"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a0ba4d7ff6bc5500427f093771c1762e6">mdf::MdfReader::IsOk</a></div><div class="ttdeci">bool IsOk() const</div><div class="ttdef"><b>Definition</b> mdfreader.h:98</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a0e19cc38b9ea526c3020398738a3db64"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a0e19cc38b9ea526c3020398738a3db64">mdf::MdfReader::ReadPartialData</a></div><div class="ttdeci">bool ReadPartialData(IDataGroup &amp;data_group, size_t min_sample, size_t max_sample)</div><div class="ttdoc">Reads a range of samples.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a21b97f7036c49f6beb2f7f5772c6fde9"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a21b97f7036c49f6beb2f7f5772c6fde9">mdf::MdfReader::ReadVlsdData</a></div><div class="ttdeci">bool ReadVlsdData(IDataGroup &amp;data_group, IChannel &amp;vlsd_channel, const std::vector&lt; uint64_t &gt; &amp;offset_list, std::function&lt; void(uint64_t, const std::vector&lt; uint8_t &gt; &amp;)&gt; &amp;callback)</div><div class="ttdoc">Read in partial variable length data with an offset list.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a2f1c16a9230973d05788b49b81ca32fd"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a2f1c16a9230973d05788b49b81ca32fd">mdf::MdfReader::ReadSrData</a></div><div class="ttdeci">bool ReadSrData(ISampleReduction &amp;sr_group)</div><div class="ttdoc">Reads in data bytes to a sample reduction (SR) block.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a3a7b46a48cac62ed16897f28f3649ba9"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a3a7b46a48cac62ed16897f28f3649ba9">mdf::MdfReader::ReadData</a></div><div class="ttdeci">bool ReadData(IDataGroup &amp;data_group)</div><div class="ttdoc">Reads all sample, sample reduction and signal data into memory.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a4e1b3dca5f2b9d0c8b80ecdf843d86ba"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a4e1b3dca5f2b9d0c8b80ecdf843d86ba">mdf::MdfReader::ReadHeader</a></div><div class="ttdeci">bool ReadHeader()</div><div class="ttdoc">Reads the ID and the HD block.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a4eb4a1808b4826a6befa2a608790e707"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a4eb4a1808b4826a6befa2a608790e707">mdf::MdfReader::ReadMeasurementInfo</a></div><div class="ttdeci">bool ReadMeasurementInfo()</div><div class="ttdoc">Reads everything but not CG and raw data.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a53daae43b08717a2178f73270188d019"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a53daae43b08717a2178f73270188d019">mdf::MdfReader::Index</a></div><div class="ttdeci">void Index(int64_t index)</div><div class="ttdef"><b>Definition</b> mdfreader.h:94</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a590c1e3a97b2a69f6e2cb203badd2282"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a590c1e3a97b2a69f6e2cb203badd2282">mdf::MdfReader::GetFile</a></div><div class="ttdeci">const MdfFile * GetFile() const</div><div class="ttdef"><b>Definition</b> mdfreader.h:111</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a64bd57d67582f7cb2f911f4d427fb5ce"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a64bd57d67582f7cb2f911f4d427fb5ce">mdf::MdfReader::ReadEverythingButData</a></div><div class="ttdeci">bool ReadEverythingButData()</div><div class="ttdoc">Reads all blocks but not raw data.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a8209013830f087b0f08a281259361108"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a8209013830f087b0f08a281259361108">mdf::MdfReader::ExportAttachmentData</a></div><div class="ttdeci">bool ExportAttachmentData(const IAttachment &amp;attachment, const std::string &amp;dest_file)</div><div class="ttdoc">Export the attachment data to a detination file.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a8d21b5d7336b34547a049e07fd1408cc"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a8d21b5d7336b34547a049e07fd1408cc">mdf::MdfReader::~MdfReader</a></div><div class="ttdeci">virtual ~MdfReader()</div><div class="ttdoc">Destructor that close any open file and destructs.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a8e6380bb34582a34eec11b693648d6d5"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a8e6380bb34582a34eec11b693648d6d5">mdf::MdfReader::ShortName</a></div><div class="ttdeci">std::string ShortName() const</div><div class="ttdoc">Returns the file name without paths.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a8f05147406ef2de50559a35c4c399abb"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a8f05147406ef2de50559a35c4c399abb">mdf::MdfReader::GetDataGroup</a></div><div class="ttdeci">IDataGroup * GetDataGroup(size_t order) const</div><div class="ttdoc">Returns the data group (DG) block.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a95758453003b0132b6324101096611b1"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a95758453003b0132b6324101096611b1">mdf::MdfReader::Open</a></div><div class="ttdeci">bool Open()</div><div class="ttdoc">Opens the file stream for reading.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_a9abc5d58be4d23b0b1c476d8a3a3a4d3"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#a9abc5d58be4d23b0b1c476d8a3a3a4d3">mdf::MdfReader::GetHeader</a></div><div class="ttdeci">const IHeader * GetHeader() const</div><div class="ttdoc">Returns the header (HD) block.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_aa7f0b2856814655ad23f99dd76bc7d44"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#aa7f0b2856814655ad23f99dd76bc7d44">mdf::MdfReader::MdfReader</a></div><div class="ttdeci">MdfReader(const std::string &amp;filename)</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_abcd1fda3384e9d538803e0504c4cc7a4"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#abcd1fda3384e9d538803e0504c4cc7a4">mdf::MdfReader::Close</a></div><div class="ttdeci">void Close()</div><div class="ttdoc">Closes the file stream.</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_af0675cacfb831f8700c9c323feb42ef8"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#af0675cacfb831f8700c9c323feb42ef8">mdf::MdfReader::Index</a></div><div class="ttdeci">int64_t Index() const</div><div class="ttdef"><b>Definition</b> mdfreader.h:86</div></div>
<div class="ttc" id="aclassmdf_1_1_mdf_reader_html_af98f1f425b626097e2728185f3c2eb8a"><div class="ttname"><a href="classmdf_1_1_mdf_reader.html#af98f1f425b626097e2728185f3c2eb8a">mdf::MdfReader::IsFinalized</a></div><div class="ttdeci">bool IsFinalized() const</div><div class="ttdoc">Return true if the file is marked as finalized.</div></div>
<div class="ttc" id="aichannelobserver_8h_html"><div class="ttname"><a href="ichannelobserver_8h.html">ichannelobserver.h</a></div><div class="ttdoc">A channel observer is holds a list of channel samples for a channel.</div></div>
<div class="ttc" id="aisamplereduction_8h_html"><div class="ttname"><a href="isamplereduction_8h.html">isamplereduction.h</a></div></div>
<div class="ttc" id="amdffile_8h_html"><div class="ttname"><a href="mdffile_8h.html">mdffile.h</a></div><div class="ttdoc">Interface against an MDF file object.</div></div>
<div class="ttc" id="anamespacemdf_html"><div class="ttname"><a href="namespacemdf.html">mdf</a></div><div class="ttdoc">Main namespace for the MDF library.</div><div class="ttdef"><b>Definition</b> canmessage.h:17</div></div>
<div class="ttc" id="anamespacemdf_html_a16a866b3ee857add084d1d8e8b2e7aa3"><div class="ttname"><a href="namespacemdf.html#a16a866b3ee857add084d1d8e8b2e7aa3">mdf::CreateChannelObserver</a></div><div class="ttdeci">ChannelObserverPtr CreateChannelObserver(const IDataGroup &amp;data_group, const IChannelGroup &amp;group, const IChannel &amp;channel)</div><div class="ttdoc">Creates and attaches a channel sample observer.</div></div>
<div class="ttc" id="anamespacemdf_html_a36bdce80788796d1ee3482bfe48c3f96"><div class="ttname"><a href="namespacemdf.html#a36bdce80788796d1ee3482bfe48c3f96">mdf::IsMdfFile</a></div><div class="ttdeci">bool IsMdfFile(const std::string &amp;filename)</div><div class="ttdoc">Returns true if the file is an MDF file.</div></div>
<div class="ttc" id="anamespacemdf_html_a5964a13a2ccb66953e040af87d62e2da"><div class="ttname"><a href="namespacemdf.html#a5964a13a2ccb66953e040af87d62e2da">mdf::ChannelObserverPtr</a></div><div class="ttdeci">std::unique_ptr&lt; IChannelObserver &gt; ChannelObserverPtr</div><div class="ttdoc">Smart pointer to an observer.</div><div class="ttdef"><b>Definition</b> mdfreader.h:22</div></div>
<div class="ttc" id="anamespacemdf_html_a704962c842a2b4ae11010c7fcb26b0de"><div class="ttname"><a href="namespacemdf.html#a704962c842a2b4ae11010c7fcb26b0de">mdf::ChannelObserverList</a></div><div class="ttdeci">std::vector&lt; ChannelObserverPtr &gt; ChannelObserverList</div><div class="ttdoc">List of observer.</div><div class="ttdef"><b>Definition</b> mdfreader.h:24</div></div>
<div class="ttc" id="anamespacemdf_html_a7d36a3f5f140f8be0a7d4bebc9be7eeb"><div class="ttname"><a href="namespacemdf.html#a7d36a3f5f140f8be0a7d4bebc9be7eeb">mdf::CreateChannelObserverForChannelGroup</a></div><div class="ttdeci">void CreateChannelObserverForChannelGroup(const IDataGroup &amp;data_group, const IChannelGroup &amp;group, ChannelObserverList &amp;dest)</div><div class="ttdoc">Creates a channel observer.</div></div>
<div class="ttc" id="anamespacemdf_html_a9cfa60a833d0bbb41342775cda9c52c1"><div class="ttname"><a href="namespacemdf.html#a9cfa60a833d0bbb41342775cda9c52c1">mdf::CreateChannelObserverForDataGroup</a></div><div class="ttdeci">void CreateChannelObserverForDataGroup(const IDataGroup &amp;data_group, ChannelObserverList &amp;dest_list)</div><div class="ttdoc">Creates channel observers for all channels within a data group.</div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.12.0
</small></address>
</div><!-- doc-content -->
</body>
</html>
